<?php
/*
 * @ https://EasyToYou.eu - IonCube v11 Decoder Online
 * @ PHP 7.2 & 7.3
 * @ Decoder version: 1.1.6
 * @ Release: 10/08/2022
 */

// Decoded file for php version 71.
namespace app\agent\model;

class LongbingPlugeKey extends \app\BaseModel
{
    protected $name = "lb_pluge_key";
    public function getPlugeKey($filter = [])
    {
        $result = $this;
        if(!empty($filter)) {
            $result = $result->where($filter);
        }
        $result = $result->limit(1)->select();
        if(!empty($result)) {
            $result = $result->toArray();
            if(isset($result[0])) {
                $result = $result[0];
            }
        }
        return $result;
    }
    public function updatePlugeKey($filter, $data = [])
    {
        $data["update_time"] = time();
        $result = $this->where($filter)->update($data);
        return !empty($result);
    }
}

?>